package com.zhao.pojo;

import com.baomidou.mybatisplus.annotation.*;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;
import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class FileComment {
    @TableId(type = IdType.AUTO)
    private Integer id;         //评论id
    private Integer fileId;
    private Integer father;
    private String bauthor;        //文章作者
    private String ip;          //评论这IP
    private String content;     //论内容
    private String author;      //评论作者
    private String score;       //评分 1-5
    private String ipHome;
    @TableLogic //逻辑删除注解
    private Integer deleted;
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;

    @TableField(exist = false)
    private String avatar;   //头像地址
    @TableField(exist = false)
    private List<FileComment> sons;//子评论

}
